import pytest

import flet as ft
import flet.testing as ftt


@pytest.mark.asyncio(loop_scope="function")
async def test_image_for_docs(flet_app_function: ftt.FletTestApp, request):
    flet_app_function.page.theme_mode = ft.ThemeMode.LIGHT
    await flet_app_function.assert_control_screenshot(
        request.node.name,
        ft.RadioGroup(
            value="option_2",
            content=ft.Column(
                intrinsic_width=True,
                controls=[
                    ft.CupertinoRadio(value="option_1", label="Option 1"),
                    ft.CupertinoRadio(value="option_2", label="Option 2"),
                    ft.CupertinoRadio(value="option_3", label="Option 3"),
                ],
            ),
        ),
    )
